package com.example.amoxicilin.null_test.main;

import android.os.Bundle;
import android.support.design.widget.FloatingActionButton;
import android.support.design.widget.Snackbar;
import android.support.v7.app.AppCompatActivity;
import android.support.v7.widget.Toolbar;
import android.view.View;
import android.widget.TextView;

import com.example.amoxicilin.null_test.R;

public class AnswerActivity extends AppCompatActivity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_answer);
        Toolbar toolbar = (Toolbar) findViewById(R.id.toolbar);
        setSupportActionBar(toolbar);

        Bundle bundle=new Bundle();
        bundle=getIntent().getExtras();
        String content=bundle.getString("AnswerContent");
        //Toast.makeText(AnswerActivity.this,content, Toast.LENGTH_SHORT).show();
        TextView textView=(TextView)findViewById(R.id.answer_detail);
        textView.setText(content);
        FloatingActionButton fab = (FloatingActionButton) findViewById(R.id.answer_fab);
        fab.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                Snackbar.make(view, "Replace with your own action", Snackbar.LENGTH_LONG)
                        .setAction("Action", null).show();
            }
        });
    }
}
